--	Package File Template
--
--	Purpose: This package defines supplemental types, subtypes, 
--		 constants, and functions 


library IEEE;
use IEEE.STD_LOGIC_1164.all;

package key_codes is
	
  -- SPECIAL KEY CODES
  constant KEY_BREAK_CODE		: std_logic_vector(7 downto 0) := X"F0";
  constant KEY_EXTEND			: std_logic_vector(7 downto 0) := X"E0";
  
  -- LETTER KEYS
  constant KEY_A				: std_logic_vector(7 downto 0) := X"1C";
  constant KEY_B				: std_logic_vector(7 downto 0) := X"32";
  constant KEY_C				: std_logic_vector(7 downto 0) := X"21";
  constant KEY_D				: std_logic_vector(7 downto 0) := X"23";
  constant KEY_E				: std_logic_vector(7 downto 0) := X"24";
  constant KEY_F				: std_logic_vector(7 downto 0) := X"2B";
  constant KEY_G				: std_logic_vector(7 downto 0) := X"34";
  constant KEY_H				: std_logic_vector(7 downto 0) := X"33";
  constant KEY_I				: std_logic_vector(7 downto 0) := X"43";
  constant KEY_J				: std_logic_vector(7 downto 0) := X"3B";
  constant KEY_K				: std_logic_vector(7 downto 0) := X"42";
  constant KEY_L				: std_logic_vector(7 downto 0) := X"4B";
  constant KEY_M				: std_logic_vector(7 downto 0) := X"3A";
  constant KEY_N				: std_logic_vector(7 downto 0) := X"31";
  constant KEY_O				: std_logic_vector(7 downto 0) := X"44";
  constant KEY_P				: std_logic_vector(7 downto 0) := X"4D";
  constant KEY_Q				: std_logic_vector(7 downto 0) := X"15";
  constant KEY_R				: std_logic_vector(7 downto 0) := X"2D";
  constant KEY_S				: std_logic_vector(7 downto 0) := X"1B";
  constant KEY_T				: std_logic_vector(7 downto 0) := X"2C";
  constant KEY_U				: std_logic_vector(7 downto 0) := X"3C";
  constant KEY_V				: std_logic_vector(7 downto 0) := X"2A";
  constant KEY_W				: std_logic_vector(7 downto 0) := X"1D";
  constant KEY_X				: std_logic_vector(7 downto 0) := X"22";
  constant KEY_Y				: std_logic_vector(7 downto 0) := X"35";
  constant KEY_Z				: std_logic_vector(7 downto 0) := X"1A";
  
  -- NUMBER KEYS
  constant KEY_0				: std_logic_vector(7 downto 0) := X"45";
  constant KEY_1				: std_logic_vector(7 downto 0) := X"16";
  constant KEY_2				: std_logic_vector(7 downto 0) := X"1E";
  constant KEY_3				: std_logic_vector(7 downto 0) := X"26";
  constant KEY_4				: std_logic_vector(7 downto 0) := X"25";
  constant KEY_5				: std_logic_vector(7 downto 0) := X"2E";
  constant KEY_6				: std_logic_vector(7 downto 0) := X"36";
  constant KEY_7				: std_logic_vector(7 downto 0) := X"3D";
  constant KEY_8				: std_logic_vector(7 downto 0) := X"3E";
  constant KEY_9				: std_logic_vector(7 downto 0) := X"46";
  
  -- ANNOTATION KEYS
  constant KEY_TILDE			: std_logic_vector(7 downto 0) := X"0E";
  constant KEY_MINUS			: std_logic_vector(7 downto 0) := X"4E";
  constant KEY_EQUALS			: std_logic_vector(7 downto 0) := X"55";
  constant KEY_BACKSLASH		: std_logic_vector(7 downto 0) := X"5D";
  constant KEY_SLASH			: std_logic_vector(7 downto 0) := X"4A";
  constant KEY_BRACKET_OPEN		: std_logic_vector(7 downto 0) := X"54";
  constant KEY_BRACKET_CLOSE	: std_logic_vector(7 downto 0) := X"5B";
  constant KEY_COLON			: std_logic_vector(7 downto 0) := X"4C";
  constant KEY_APOSTROPHE		: std_logic_vector(7 downto 0) := X"52";
  constant KEY_COMMA			: std_logic_vector(7 downto 0) := X"41";
  constant KEY_DOT				: std_logic_vector(7 downto 0) := X"49";
  
  -- CONTROL KEYS
  constant KEY_BACKSPACE		: std_logic_vector(7 downto 0) := X"66";
  constant KEY_SPACE			: std_logic_vector(7 downto 0) := X"29";
  constant KEY_TAB				: std_logic_vector(7 downto 0) := X"0D";
  constant KEY_CAPSLOCK			: std_logic_vector(7 downto 0) := X"58";
  constant KEY_SHIFT_L			: std_logic_vector(7 downto 0) := X"12";
  constant KEY_CTRL_L			: std_logic_vector(7 downto 0) := X"14";
  constant KEY_WIN_L			: std_logic_vector(7 downto 0) := X"1F";
  constant KEY_ALT_L			: std_logic_vector(7 downto 0) := X"11";
  constant KEY_SHIFT_R			: std_logic_vector(7 downto 0) := X"59";
  constant KEY_CTRL_R			: std_logic_vector(7 downto 0) := X"14";
  constant KEY_WIN_R			: std_logic_vector(7 downto 0) := X"27";
  constant KEY_ALT_R			: std_logic_vector(7 downto 0) := X"11";
  constant KEY_MENU				: std_logic_vector(7 downto 0) := X"2F";
  constant KEY_ENTER			: std_logic_vector(7 downto 0) := X"5A";
  constant KEY_ESC				: std_logic_vector(7 downto 0) := X"76";
  
  -- FUNCTION KEYS
  constant KEY_F1				: std_logic_vector(7 downto 0) := X"05";
  constant KEY_F2				: std_logic_vector(7 downto 0) := X"06";
  constant KEY_F3				: std_logic_vector(7 downto 0) := X"04";
  constant KEY_F4				: std_logic_vector(7 downto 0) := X"0C";
  constant KEY_F5				: std_logic_vector(7 downto 0) := X"03";
  constant KEY_F6				: std_logic_vector(7 downto 0) := X"0B";
  constant KEY_F7				: std_logic_vector(7 downto 0) := X"83";
  constant KEY_F8				: std_logic_vector(7 downto 0) := X"0A";
  constant KEY_F9				: std_logic_vector(7 downto 0) := X"01";
  constant KEY_F10				: std_logic_vector(7 downto 0) := X"09";
  constant KEY_F11				: std_logic_vector(7 downto 0) := X"78";
  constant KEY_F12				: std_logic_vector(7 downto 0) := X"07";
  
  -- SPECIAL FUNCTIONS
  --constant KEY_PRNT_SCRN		: std_logic_vector(7 downto 0) := X"00";	--complex function, NOT IMPLEMENTED
  constant KEY_SCROLL_LOCK		: std_logic_vector(7 downto 0) := X"7E";
  --constant KEY_PAUSE				: std_logic_vector(7 downto 0) := X"00";	--complex function, NOT IMPLEMENTED
  constant KEY_INSERT			: std_logic_vector(7 downto 0) := X"70";
  constant KEY_HOME				: std_logic_vector(7 downto 0) := X"6C";
  constant KEY_PAGE_UP			: std_logic_vector(7 downto 0) := X"7D";
  constant KEY_DELETE			: std_logic_vector(7 downto 0) := X"71";
  constant KEY_END				: std_logic_vector(7 downto 0) := X"69";
  constant KEY_PAGE_DOWN		: std_logic_vector(7 downto 0) := X"7A";
  
  -- ARROW KEYS
  constant KEY_UP				: std_logic_vector(7 downto 0) := X"75";
  constant KEY_LEFT				: std_logic_vector(7 downto 0) := X"6B";
  constant KEY_DOWN				: std_logic_vector(7 downto 0) := X"72";
  constant KEY_RIGHT			: std_logic_vector(7 downto 0) := X"74";
  
  -- NUMPAD
  constant KEY_NUM_LOCK			: std_logic_vector(7 downto 0) := X"77";
  constant KEY_NUMPAD_SLASH		: std_logic_vector(7 downto 0) := X"4A";
  constant KEY_NUMPAD_TIMES		: std_logic_vector(7 downto 0) := X"7C";
  constant KEY_NUMPAD_MINUS		: std_logic_vector(7 downto 0) := X"7B";
  constant KEY_NUMPAD_PLUS		: std_logic_vector(7 downto 0) := X"79";
  constant KEY_NUMPAD_ENTER		: std_logic_vector(7 downto 0) := X"5A";
  constant KEY_NUMPAD_DOT		: std_logic_vector(7 downto 0) := X"71";
  constant KEY_NUMPAD_0			: std_logic_vector(7 downto 0) := X"70";
  constant KEY_NUMPAD_1			: std_logic_vector(7 downto 0) := X"69";
  constant KEY_NUMPAD_2			: std_logic_vector(7 downto 0) := X"72";
  constant KEY_NUMPAD_3			: std_logic_vector(7 downto 0) := X"7A";
  constant KEY_NUMPAD_4			: std_logic_vector(7 downto 0) := X"6B";
  constant KEY_NUMPAD_5			: std_logic_vector(7 downto 0) := X"73";
  constant KEY_NUMPAD_6			: std_logic_vector(7 downto 0) := X"74";
  constant KEY_NUMPAD_7			: std_logic_vector(7 downto 0) := X"6C";
  constant KEY_NUMPAD_8			: std_logic_vector(7 downto 0) := X"75";
  constant KEY_NUMPAD_9			: std_logic_vector(7 downto 0) := X"7D";
end key_codes;